{% extends 'enterprise/base.html' %}

{% block css %}
{% endblock %}

{% block content %}
<script type="text/javascript">
    var primary_menu = "menu_2";
    var sub_menu = "menu_2_2";
</script>
<div class="col-md-12">
    <div class="panel panel-primary">
        <div class="panel-heading">
            <div class="panel-title"><h3>贮罐单元</h3></div>
            <div class="panel-options">
                <a href="#" data-rel="collapse"><i class="entypo-down-open"></i></a>
                <!--<a href="#" data-rel="reload"><i class="entypo-arrows-ccw"></i></a>-->
            </div>
        </div>
        <div class="panel-body with-table">

        <form action='' method='POST' class="formSubmit">
            <table class="input_in table-detail">
                <tr>
                    <th width="200">贮存物料名称</th>
                    <td><input datatype="*" name='name' value='{{ st.name }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>对应产品</th>
                    <td><input datatype="*" name='to_product' value='{{ st.to_product }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>贮罐形式</th>
                    <td><input datatype="*" name='mode' value='{{ st.mode }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>有无氮封</th>
                    <td>
                        <!-- <select name='nitrogen_sealed' value='{{ st.nitrogen_sealed }}'>
                            <option value=''>有</option>
                            <option value=''>无</option>
                        </select> -->
                        <select name='nitrogen_sealed'>
                            <option value='是'>是</option>
                            <option value='否'>否</option>
                        </select>
                    </td>
                </tr>
                <tr>
                    <th>贮罐规格</th>
                    <td>
                        <select name='para' value='{{ st.para }}'>
                            <option value='固定顶'>固定顶</option>
                            <option value='浮顶'>浮顶</option>
                            <option value='卧式'>卧式</option>
                        </select>
                    </td>
                </tr>
                <tr>
                    <th>贮罐数量</th>
                    <td><input datatype="n" name='count' value='{{ st.count }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>设备年故障率</th>
                    <td><input datatype="*" name='error_rate' value='{{ st.error_rate }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>年维护频次</th>
                    <td><input datatype="*" name='repair_rate' value='{{ st.repair_rate }}' type="text" placeholder="请输入"></td>
                </tr>
                <tr>
                    <th>有无监控设施</th>
                    <td>
                        <select name='is_monit'>
                            <option value='有'>有</option>
                            <option value='无'>无</option>
                        </select>
                    </td>
                </tr>
            </table>
        
        </div>
    </div>
    <div class="buttons">
        <!-- <input onclick="submitSave()" type="submit" class="btn btn-orange btn-lg" value="暂存"> -->
                                <input type="submit" class="btn btn-success btn-lg" value="保存">
        <input class="btn btn-info btn-lg" type="reset" value="重置"/>
    </div>
    </form>
</div>
{% endblock %}

{% block js %}
    <script>
        $(function(){
            $('select[name=para]').val('{{ st.para }}');
            $('select[name=nitrogen_sealed]').val('{{ st.nitrogen_sealed }}');
            $('select[name=is_monit]').val('{{ st.is_monit }}');
        })
    </script>
{% endblock %}